﻿using System;
using System.Windows.Controls;

namespace Hibiku.Views
{
    public partial class TweetComposerView
    {
        private bool _caretIndexSet = false;

        public TweetComposerView()
        {
            InitializeComponent();
        }

        private void HandleTextChanged(object sender, TextChangedEventArgs e)
        {
            if (!_caretIndexSet)
            {
                _textBox.CaretIndex = Math.Max(0, _textBox.Text.Length);

                _caretIndexSet = true;
            }
        }
    }
}
